package org.textplantform.common.core.spring;

import org.springframework.beans.BeansException;
import org.springframework.beans.factory.config.BeanPostProcessor;
import org.textplantform.common.core.LoggerSupport;

public abstract class BaseBeanPostProcessor extends LoggerSupport implements BeanPostProcessor {
    public BaseBeanPostProcessor() {
        super();
        logger.error("BeanPostProcessor 构造");
    }

    @Override
    public Object postProcessAfterInitialization(Object bean, String beanName)
            throws BeansException {
    	logger.info("AFTER beanName: {} beanClass :{} ",beanName,bean.getClass());
        return bean;
    }

    @Override
    public Object postProcessBeforeInitialization(Object bean, String beanName)
            throws BeansException {
    	logger.info("BEFORE beanName: {} beanClass :{} ",beanName,bean.getClass());
        return bean;
    }
}